export default defineEventHandler(async (event) => {
    try {
        const query = await getQuery(event);
        console.log(query)
        let res: any = await $fetch('https://hunhepan.com/open/search/disk', {
            method: 'POST',
            body: {
                exact: true,
                page: Number(query.page),
                q: query.keyword,
                size: Number(query.size),
            }
        })
        return {
            code: 200,
            data: {
                total: res.data.total,
                list: res.data.list
            }
        }
    } catch (e) {
        return {
            code: 500,
            msg: 'error',
        }
    }
})